package com.shigui.news.exception;

import com.shigui.news.enums.ResponseCode;

public class BaseException extends RuntimeException {
	
	protected String code;
	
	public BaseException(ResponseCode responseCode){
		super(responseCode.getDescription());
		this.code = responseCode.getCode();
	}
	
	public BaseException(String code, String message){
		
		super(message);
		this.code = code;
		
	}

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}
	
}
